package com.xbzl.cly_demo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
//import lombok.Data;

/**
 * 
 * @TableName vehicle_abnormal_records
 */
@TableName(value ="vehicle_abnormal_records")
//@Data
public class VehicleAbnormalRecords implements Serializable {
    public Long getExceptionid() {
        return exceptionid;
    }

    public void setExceptionid(Long exceptionid) {
        this.exceptionid = exceptionid;
    }

    public Long getVehicleid() {
        return vehicleid;
    }

    public void setVehicleid(Long vehicleid) {
        this.vehicleid = vehicleid;
    }

    public LocalDateTime getTime() {
        return time;
    }

    public void setTime(LocalDateTime time) {
        this.time = time;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    /**
     * 
     */
    @TableId(value = "exceptionId", type = IdType.AUTO)
    private Long exceptionid;

    /**
     * 
     */
    @TableField(value = "vehicleId")
    private Long vehicleid;

    /**
     * 
     */
    @TableField(value = "time")
    private LocalDateTime time;

    /**
     * 
     */
    @TableField(value = "type")
    private String type;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        VehicleAbnormalRecords other = (VehicleAbnormalRecords) that;
        return (this.getExceptionid() == null ? other.getExceptionid() == null : this.getExceptionid().equals(other.getExceptionid()))
            && (this.getVehicleid() == null ? other.getVehicleid() == null : this.getVehicleid().equals(other.getVehicleid()))
            && (this.getTime() == null ? other.getTime() == null : this.getTime().equals(other.getTime()))
            && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getExceptionid() == null) ? 0 : getExceptionid().hashCode());
        result = prime * result + ((getVehicleid() == null) ? 0 : getVehicleid().hashCode());
        result = prime * result + ((getTime() == null) ? 0 : getTime().hashCode());
        result = prime * result + ((getType() == null) ? 0 : getType().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", exceptionid=").append(exceptionid);
        sb.append(", vehicleid=").append(vehicleid);
        sb.append(", time=").append(time);
        sb.append(", type=").append(type);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}